package org.example.transaction;

import org.example.session.TransactionIsolationLevel;

import javax.sql.DataSource;
import java.sql.Connection;

/**
 * @Author: luyg
 * @Date: 2024/11/11/9:26
 * @Description: 事务工厂接口
 */
public interface TransactionFactory {

    Transaction newTransaction(Connection conn);
    Transaction newTransaction(DataSource dataSource, TransactionIsolationLevel level, boolean autoCommit);
}
